package com.tulele.vtool.mapper;

import com.tulele.vtool.model.GzhBrandMap;
import com.tulele.vtool.model.GzhUserMap;
import com.tulele.vtool.model.SysGzh;
import com.tulele.vtool.model.SysRealmMessage;
import com.tulele.vtool.model.combinedEntity.SlideshowCombinedEntity;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

import java.util.List;

@Component(value = "sysGzhMapper")
public interface SysGzhMapper {
    SysGzh selectCacheLinkByGzhCode(@Param("gzhCode")String gzhCode);

    SysGzh selectCacheLinkByAppId(@Param("appId")String appId);

    GzhBrandMap getGzhBrandMap(@Param("brandId") Integer brandId);

    List<Integer> getGzhBrandMapByGzh(@Param("gzhCode")String gzhCode);

    int addGzhUserMap(GzhUserMap gzhUserMap);

    GzhUserMap  getGzhUserMap(@Param("sUserId") Integer sUserId,@Param("tGzhCode") String tGzhCode);

    GzhUserMap  checkGzhUserMap(@Param("sUserId") Integer sUserId,@Param("tUserId") Integer tUserId);

    List<SysRealmMessage> getRealmByGzhCode(@Param("gzhCode")String gzhCode);

    /**
     * 根据会员状态获取公众号的访问域名
     * @param gzhCode 公众号标识
     * @return
     */
    SysRealmMessage getGzhCodeRealmByVipStatus(String gzhCode);

    /**
     * 获取公众号的轮播图
     * @param gzhCode 公众号标识
     * @return 公众号的轮播图列表
     */
    List<SlideshowCombinedEntity> getGzhSlideshow(String gzhCode);
}
